package com.dailyblue.java.spring.cloud.example.sentinel.customer.feign;

import com.dailyblue.java.spring.cloud.example.commons.util.JsonResult;
import com.dailyblue.java.spring.cloud.example.sentinel.customer.feign.exception.ProductFeignHandler;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(value = "sentinel-product", fallback = ProductFeignHandler.class)
public interface ProductFeign {
    @GetMapping("/product/a")
    JsonResult a();

    @GetMapping("/product/b")
    JsonResult b();

    @GetMapping("/product/c/{index}")
    JsonResult c(@PathVariable("index") Integer index);

}
